package test;

import com.search.BinarySearch;

import java.util.Arrays;

public class test {
    public static void main(String[] args){
        int[] list = { 4, 5, 89, 1, 996, 4, 29, 1, 4, 8 };
        Arrays.sort(list);
        System.out.print("list数组：");
        for(int i : list){
            System.out.print(i + ",");
        }
        System.out.println();
        // 要寻找的值
        int key = 5;
        System.out.print(BinarySearch.rank(key,list));
    }
}
